package com.dobbinsoft.iotechn.device.entity;

import com.dobbinsoft.iotechn.device.domain.ProductDataDO;
import lombok.Data;

import java.util.Date;
import java.util.List;
import java.util.Map;

/**
 * Description:
 * User: rize
 * Date: 2020/6/26
 * Time: 15:15
 */
@Data
public class DeviceSessionEntity {

    private Long id;

    private Long productId;

    private Long developerId;

    private String title;

    private Integer status;

    private String accessKeyId;

    private String accessKeySecret;

    private String lastIp;

    private String gmtActive;

    private Long userId;

    private Integer authType;

    /**
     * 此次连接设备信用，
     * 若设备超频率上报数据，
     * 服务器将认为设备属于恶意访问，
     * 将扣除信用，
     * 若信用被扣完，服务器将主动断开此设备
     */
    private Integer credit;

    /**
     * 产品预设定义数据点，用于限流
     */
    private Map<String, ProductDataDO> productDataMap;

    private Date gmtUpdate;

    private Date gmtCreate;

}
